package com.example.cafe.work.mapper;


import com.example.cafe.work.dto.UserDTO;
import com.example.cafe.work.model.User;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.example.cafe.work.model.Userinfo;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author hua
 * @since 2024-09-16
 */
@Mapper
public interface UserMapper extends BaseMapper<User> {
    @Insert("insert into tb_userinfo(user_id) values (#{userInfo.userId})")
    int addUserInfo(@Param("userInfo")Userinfo userinfo);

    List<UserDTO> selectPage1(@Param("start") int start,@Param("size") int size,@Param("name") String name);

}
